FROM centos:latest
ADD jdk-8u172-linux-x64.tar.gz /usr/local
MAINTAINER zhangjw

RUN  yum -y install kde-l10n-Chinese telnet && \
	     yum -y reinstall glibc-common &&\
              yum clean all  && \
                localedef -c -f UTF-8 -i zh_CN zh_CN.utf8

ENV LANG C.UTF-8
ENV LC_ALL "zh_CN.UTF-8"

#设置时区
ENV  TIME_ZONE Asia/Shanghai
RUN ln -sf /usr/share/zoneinfo/${TIME_ZONE} /etc/localtime
#******************设置JAVA变量环境******************
ENV JAVA_HOME=/usr/local/jdk1.8.0_172
ENV CLASSPATH=$JAVA_HOME/bin
ENV PATH=.:$JAVA_HOME/bin:$PATH
CMD ["java","-version"]